CXXFLAGS = -I../.. -I.. -g -Wall
target = regex
regex = nfa.o dfa.o

$(target): $(patsubst %.cpp,%.o,$(wildcard *.cpp)) $(regex)
	g++ -o $@ $^

$(regex): %.o: ../../regex/%.cpp
	g++ $(CXXFLAGS) -c -o $@ $^

clean:
	-rm *.o
	-rm $(target)
